package dp.decorator.io;

import java.io.FileInputStream;
import java.io.IOException;

public class App {

	public static void main(String[] args) {
		String path = App.class.getResource("").getPath();
		System.out.println(path);
		try {
			LowerCaseInputStream lci = new LowerCaseInputStream(new FileInputStream(path+"test.txt"));
			StringBuffer sbf = new StringBuffer();
			int data;
			while((data=lci.read())!=-1)
			{
				sbf.append((char)data);
			}
			System.out.println(sbf.toString());
		} catch (IOException e) {
			e.printStackTrace();
		}
	}
}
